package com.ruoyi.facilityStatus.service.impl;

import java.util.List;

import com.ruoyi.facilityInfo.domain.FacilityInfo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.facilityStatus.mapper.FacilityStatusMapper;
import com.ruoyi.facilityStatus.service.IFacilityStatusService;

/**
 * 设施状态Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-07-04
 */
@Service
public class FacilityStatusServiceImpl implements IFacilityStatusService
{
    @Autowired
    private FacilityStatusMapper facilityStatusMapper;

    /**
     * 查询设施状态
     * 
     * @param facilityId 设施状态主键
     * @return 设施状态
     */
    @Override
    public FacilityInfo selectFacilityInfoByFacilityId(Long facilityId)
    {
        return facilityStatusMapper.selectFacilityInfoByFacilityId(facilityId);
    }

    /**
     * 查询设施状态列表
     * 
     * @param facilityInfo 设施状态
     * @return 设施状态
     */
    @Override
    public List<FacilityInfo> selectFacilityInfoList(FacilityInfo facilityInfo)
    {
        return facilityStatusMapper.selectFacilityInfoList(facilityInfo);
    }

    /**
     * 新增设施状态
     * 
     * @param facilityInfo 设施状态
     * @return 结果
     */
    @Override
    public int insertFacilityInfo(FacilityInfo facilityInfo)
    {
        return facilityStatusMapper.insertFacilityInfo(facilityInfo);
    }

    /**
     * 修改设施状态
     * 
     * @param facilityInfo 设施状态
     * @return 结果
     */
    @Override
    public int updateFacilityInfo(FacilityInfo facilityInfo)
    {
        return facilityStatusMapper.updateFacilityInfo(facilityInfo);
    }

    /**
     * 批量删除设施状态
     * 
     * @param facilityIds 需要删除的设施状态主键
     * @return 结果
     */
    @Override
    public int deleteFacilityInfoByFacilityIds(Long[] facilityIds)
    {
        return facilityStatusMapper.deleteFacilityInfoByFacilityIds(facilityIds);
    }

    /**
     * 删除设施状态信息
     * 
     * @param facilityId 设施状态主键
     * @return 结果
     */
    @Override
    public int deleteFacilityInfoByFacilityId(Long facilityId)
    {
        return facilityStatusMapper.deleteFacilityInfoByFacilityId(facilityId);
    }
}
